<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>第6篇 技巧型设计模式 - 第40章 MVVM模式</title>
</head>
<body>
    <!-- 
        MVVM: Model-Wiew-ViewModel

        为视图层定做一套视图模型，并在视图模型中创建属性和方法，为视图层绑定数据并实现交互
     -->
     <div class="first" data-bind="type: 'slider', data: demo1"></div>
     <div class="second" data-bind="type: 'slider', data: demo2"></div>
     <div class="third" data-bind="type: 'progressbar', data: demo3"></div>
     <script src="40-1.js"></script>
</body>
</html>